<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>项目评级结果-欢迎页</title>
<link href="__PUBLIC__/admin/css/style.css" rel="stylesheet" type="text/css" />
<script language="JavaScript" src="__PUBLIC__/admin/js/jquery.js"></script>

<link href="__PUBLIC__/admin/css/select.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="__PUBLIC__/admin/js/jquery.idTabs.min.js"></script>
<script type="text/javascript" src="__PUBLIC__/admin/js/select-ui.min.js"></script>

<link href="__PUBLIC__/validform/Validform.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="__PUBLIC__/validform/Validform_v5.3.2.js"></script>
<script type="text/javascript" src="__PUBLIC__/validform/Validform_Datatype.js"></script>

<link rel="stylesheet" href="__PUBLIC__/kindeditor/themes/default/default.css" />
<script type="text/javascript" src="__PUBLIC__/kindeditor/kindeditor-min.js"></script>
<script type="text/javascript" src="__PUBLIC__/kindeditor/lang/zh-CN.js"></script>

<script type="text/javascript">
var editor;
KindEditor.ready(function(K) {
	editor = K.create('textarea[id="item_content"]', {
		uploadJson : '{:U('kindeditor/upload_json',array('dir'=>image))}',
		fileManagerJson : '{:U('kindeditor/file_manager_json')}',
		allowFileManager : true,
		urlType : 'domain',
		afterCreate : function() {
			this.sync(); 
		},
		afterBlur:function(){ 
			this.sync(); 
		}
	});
	editor.readonly(true);
});
$(document).ready(function(e) {
    $("#indus_id,#item_province,#item_city").uedSelect({
		width : 150			  
	});

	if("{$iteminfo.item_province}".length>0 ){
		showcity("{$iteminfo.item_province}");//初始化市
	}
});

function showcity(province){
	$("#item_city").empty();
	if(province.length>0){
		$("#item_city").append("<option value='' selected>请选择市</option>");
		if("{$iteminfo.item_city}".length>0 && "{$iteminfo.item_province}"==province){
			$("#item_city").prev().find(".uew-select-text").html("{$iteminfo.item_city}");
		}else{
			$("#item_city").prev().find(".uew-select-text").html("请选择市");
		}
		$.getJSON("{:U('itemrate/getcity')}&province="+province,function(result){
			var data=result.data;
			$.each(data, function(i, v){
				if("{$iteminfo.item_city}"==v['city']){
					$("#item_city").append("<option value='"+v['city']+"' selected>"+v['city']+"</option>");
				}else{
					$("#item_city").append("<option value='"+v['city']+"'>"+v['city']+"</option>");
				}
			});
		});
	}
}
</script>
</head>

<body>
	<div class="place">
		<span>位置：</span>
		<ul class="placeul">
			<li><a href="{:U('index/welcome')}">首页</a></li>
			<li><a href="{:U('itemrate/index')}">项目评级</a></li>
			<li><a href="#">项目评级结果</a></li>
		</ul>
    </div>
    
    <div class="formbody">
		<div class="formtitle"><span>项目评级（项目信息）[{$iteminfo.item_name}]</span></div>
		<ul class="forminfo">
			<li><label>项目名称</label><input name="info[item_name]" id="item_name" type="text" class="dfinput" datatype="*5-30" errormsg="项目名称范围在5~30位之间！" maxlength="50" value="{$iteminfo.item_name}" readonly /><i class="Validform_checktip"></i></li>
			<li><label>行业分类</label>
				<div class="vocation">
					<select id="indus_id" name="info[indus_id]" datatype="*" errormsg="行业分类不能为空！" disabled>
						<option value="" selected>请选择行业分类</option>
						<volist name="indusinfo" id="data" key="key">
						<option value="{$data.indus_id}" <if condition="$data.indus_id eq $iteminfo['indus_id']">selected</if> <if condition="$data.childnum gt 0">disabled</if>>{$data.indus_title}</option>
							<if condition="$data.childnum gt 0">
								<volist name="data.child" id="child" key="keyc">
								<option value="{$child.indus_id}" <if condition="$child.indus_id eq $iteminfo['indus_id']">selected</if>>--{$child.indus_title}</option>
								</volist>
							</if>
						</volist>
					</select>
				</div>
				<i class="Validform_checktip"></i>
			</li>
			<li><label>地域信息</label>
				<div class="vocation">
					<select id="item_province" name="info[item_province]" datatype="*" errormsg="省不能为空！" onchange="showcity(this.value);" disabled>
						<option value="" selected>请选择省</option>
						<volist name="provinces" id="data" key="key">
						<option value="{$data.province}" <if condition="$data.province eq $iteminfo['item_province']">selected</if>>{$data.province}</option>
						</volist>
					</select>
				</div>
				<div class="vocation" style="padding-left:10px;">
					<select id="item_city" name="info[item_city]" datatype="*" errormsg="市不能为空！" disabled>
						<option value="">请选择市</option>
					</select>
				</div>
				<i class="Validform_checktip"></i>
			</li>
			<li><label>公司名称</label><input name="info[item_company]" id="item_company" type="text" class="dfinput" datatype="*"  errormsg="公司名称不能为空！" maxlength="50" value="{$iteminfo.item_company}" readonly  /><i class="Validform_checktip"></i></li>
			<li><label>公司地址</label><input name="info[item_address]" id="item_address" type="text" class="dfinput" datatype="*" errormsg="公司地址不能为空！" maxlength="100" value="{$iteminfo.item_address}" readonly  /><i class="Validform_checktip"></i></li>
			<li><label>联系人</label><input name="info[item_linkmen]" id="item_linkmen" type="text" class="dfinput" datatype="*2-10" errormsg="联系人在2~10位之间！" maxlength="20" value="{$iteminfo.item_linkmen}" readonly  /><i class="Validform_checktip"></i></li>
			<li><label>联系电话</label><input name="info[item_linkphone]" id="item_linkphone" type="text" class="dfinput" datatype="*"  errormsg="联系电话不能为空或格式不正确" maxlength="phone|mobile" maxlength="30" value="{$iteminfo.item_linkphone}" readonly  /><i class="Validform_checktip"></i></li>
			<li><label>项目简介</label><textarea name="info[item_content]" id="item_content" cols="" rows="" class="textinput" readonly style="height: 250px;width:700px;">{$iteminfo.item_content}</textarea></li>
			<li><label>评分</label><input name="info[score]" id="score" type="text" class="dfinput" datatype="n2-10" errormsg="评分2~5位之间！" maxlength="5" value="{$iteminfo.score}" readonly  /><i class="Validform_checktip"></i></li>

			<li><label>&nbsp;</label><input name="loginbtn" type="button" class="btn" value="返回项目评级" onclick="location.href='{:U('itemrate/index')}'" /><input name="loginbtn" type="button" class="btn" value="返回项目手动打分" onclick="location.href='{:U('itemrate/iteminfo')}'" /></li>
		</ul>
    
    </div>

	<script>
	$(function(){
		/*
		$("#myform").Validform({
			//tiptype:2
			tiptype:function(msg,o,cssctl){
				var objtip=o.obj.siblings(".Validform_checktip");
				cssctl(objtip,o.type);
				objtip.text(msg);
			}
		});
		*/
	}); 
	</script>
</body>

</html>
